-
Notifications
You must be signed in to change notification settings - Fork 572
fix(integrations): langchain add multimodal content transformation functions for images, audio, and files #5278
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: master
Are you sure you want to change the base?
Conversation
…eport-binary-data
Semver Impact of This PR🟢 Patch (bug fixes) 📋 Changelog PreviewThis is how your changes will appear in the changelog. New Features ✨
Bug Fixes 🐛
Documentation 📚
Internal Changes 🔧
🤖 This preview updates automatically when you update the PR. |
| "file_id": content_block.get("file_id", ""), | ||
| } | ||
|
|
||
| # Handle legacy image_url format (OpenAI style) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
langchain supports providing content in a provider-native format.
So, I'm wondering whether we are deliberately only handling langchain-standard blocks and OpenAI-formatted blocks?
See https://docs.langchain.com/oss/python/langchain/messages#message-content
| header, content = url.split(",", 1) | ||
| mime_type = header.split(":")[1].split(";")[0] if ":" in header else "" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'm worried about inconsistencies in the URI decoding across different AI integrations. Can this be centralized?
Description
Add more support on message types for
gen_ai.request.messagesIssues
Closes: https://linear.app/getsentry/issue/TET-1637/redact-images-langchain